home *** CD-ROM | disk | FTP | other *** search
/ Ahoy 1987 May / Ahoy_Magazine_87-05_1987_Double_L_Side_A.d64 / dir 1 (.txt) < prev    next >
Commodore BASIC  |  2022-10-26  |  10KB  |  289 lines

  1. 60 clr:gosub4000
  2. 80 dim p$(25),in$(25,5):gosub5000
  3. 100 poke53280,2:poke53281,0:printchr$(14):gosub2500:gosub5900
  4. 120 gosub800
  5. 140 h=1:g=0:l=8:lc=55590:p=8
  6. 150 fori=8to19:g=g+1:printleft$(l$,i)tab(14)"[154]"p$(g):next
  7. 204 f=len(p$(h)):fori=0tof:pokelc+i,7:next:gosub1000
  8. 205 printleft$(l$,p)tab(10)pt$
  9. 206 getan$:ifan$=""then206
  10. 208 ifan$=chr$(17)then1250
  11. 210 ifan$=chr$(145)then1300
  12. 215 ifan$=chr$(13)then2000
  13. 220 ifan$=chr$(32)andg=>24thengosub3000:goto140
  14. 222 ifan$=chr$(32)thengosub3000:h=13:lc=55590:p=8:goto150
  15. 225 goto204
  16. 230 print"[147]";:poke53280,0:poke53281,6
  17. 235 print"[158][204]oading...";chr$(34);p$(h)chr$(34);""
  18. 240 print "load";chr$(34);p$(h);chr$(34);",8"
  19. 250 print "run":print "[145][145][145][145][145][145][145][145][145]"
  20. 260 poke 631,13:poke 632,13:poke 198,2:end
  21. 800 print"[147]":printleft$(l$,2)tab(2)"[158][176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  22. 810 printleft$(l$,3)tab(2)"[158][221]  [154][176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174][158]  [221]"
  23. 820 fori=1to16:printtab(2)"[221]  [154][221]                            [221][158]  [221]":next
  24. 830 printleft$(l$,20)tab(2)"[221]  [154][173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189][158]  [221]"
  25. 835 printleft$(l$,21)tab(2)"[158][173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  26. 840 printleft$(l$,22)tab(1)"[155][176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  27. 850 printleft$(l$,23)tab(1)"[221] [158][195]rsr[155]=[211]elect  [211]pc[155]=[205]ore  [195]/[210][155]=[197]xecute [221]"
  28. 860 printleft$(l$,24)tab(1)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  29. 870 printleft$(l$,4)tab(10)"[176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  30. 880 printtab(10)"[221] [205] [193] [201] [206]  [205] [197] [206] [213] [221]"
  31. 890 printtab(10)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  32. 900 return
  33. 1000 s=54272:pokes+23,0:pokes+24,15
  34. 1010 pokes+6,0:pokes+5,12:pokes+1,70:pokes+3,40
  35. 1020 pokes+4,0:pokes+4,65:ford=1to100:next:pokes+4,0:return
  36. 1250 printleft$(l$,p)tab(10)"[154]  ":fori=0tof:pokelc+i,14:next
  37. 1260 h=h+1:ifh>gthenh=h-12
  38. 1262 p=p+1:ifp>19thenp=8
  39. 1265 lc=lc+40:iflc>56030thenlc=55590
  40. 1270 goto204
  41. 1300 printleft$(l$,p)tab(10)"[154]  ":fori=0tof:pokelc+i,14:next
  42. 1310 h=h-1:ifh<g-11thenh=h+12
  43. 1312 p=p-1:ifp<8thenp=19
  44. 1315 lc=lc-40:iflc<55590thenlc=56030
  45. 1320 goto204
  46. 1550 sys828
  47. 1560 printleft$(l$,13)tab(4)"[176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  48. 1570 printleft$(l$,14)tab(4)"[221] [212]his is a 128 [208]rogram.[201]t may [221]"
  49. 1580 printleft$(l$,15)tab(4)"[221] not be loaded in the 64 mode.[221]"
  50. 1590 printleft$(l$,16)tab(4)"[221] [217]ou must switch to the 128   [221]"
  51. 1600 printleft$(l$,17)tab(4)"[221] mode in order to load this   [221]"
  52. 1610 printleft$(l$,18)tab(4)"[221] program successfully. [213]se the[221]"
  53. 1620 printleft$(l$,19)tab(4)"[221] prescribed method which is...[221]"
  54. 1630 printleft$(l$,20)tab(4)"[221] [196][204]oad ''[208]rogname''           [221]"
  55. 1640 printleft$(l$,21)tab(4)"[221]       [158][[208]ress any [203]ey]        [221]"
  56. 1650 printleft$(l$,22)tab(4)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  57. 1660 printleft$(l$,23)tab(3)"[155]                                  ":gosub1000
  58. 1670 getan$:ifan$=""then1670
  59. 1680 sys882:goto225
  60. 1997 rem **************************
  61. 1998 rem ****  window routine  ****
  62. 1999 rem **************************
  63. 2000 sys828
  64. 2010 printleft$(l$,5)tab(11)"[176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  65. 2030 printleft$(l$,6)tab(11)"[221][211]ee [201]nstructions[221]"
  66. 2040 printleft$(l$,7)tab(11)"[221][210]un [208]rogram     [221]"
  67. 2050 printleft$(l$,8)tab(11)"[221][195]ancel [215]indow   [221]"
  68. 2060 printleft$(l$,9)tab(11)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  69. 2070 po=55507:x=0
  70. 2080 fori=1to16:pokepo+i,1:next:gosub1000
  71. 2090 getan$:ifan$=""then2090
  72. 2100 ifan$=chr$(17)thengosub2200:po=po+40:x=x+1:ifpo>55587thenpo=55507
  73. 2110 ifx>2thenx=0
  74. 2120 ifan$=chr$(13)then2140
  75. 2130 goto2080
  76. 2140 ifx=0thensys882:goto4100
  77. 2145 ifx=2then2160
  78. 2146 ifh=3orh=5orh=8orh=14orh=21orh=22thensys882:goto1550
  79. 2159 ifx=1thensys882:goto230
  80. 2160 sys882:goto225
  81. 2200 fori=1to16:pokepo+i,5:next:return
  82. 2500 p$(1)="[198]lankspeed"
  83. 2510 p$(2)="64 [194]ug [210]ep"
  84. 2520 p$(3)="128 [194]ug [210]ep."
  85. 2530 p$(4)="64 [194]ug [210]ep [201][201]"
  86. 2540 p$(5)="128 bug rep 2"
  87. 2550 p$(6)="[205]oondog"
  88. 2560 p$(7)="[215]all [195]rawler"
  89. 2570 p$(8)="128 startup"
  90. 2580 p$(9)="[211]cavenger [200]unt"
  91. 2590 p$(10)="[199]raphic [215]edge"
  92. 2600 p$(11)="[201]llusion [205]aster"
  93. 2610 p$(12)="[205]agic [211]quare"
  94. 2615 p$(13)="[205]agic [211]quare 2"
  95. 2620 p$(14)="magic square 128"
  96. 2630 p$(15)="[207]utcast [207]rder"
  97. 2640 p$(16)="[207]utcast [207]rder 2"
  98. 2650 p$(17)="[207]utcast [207]rder 3"
  99. 2660 p$(18)="[208]ower [208]roduct"
  100. 2670 p$(19)="[208]ower [208]roduct 2"
  101. 2690 p$(20)="[208]hrase [210]everser"
  102. 2700 p$(21)="phrase rev 128"
  103. 2710 p$(22)="128 helpkey"
  104. 2720 p$(23)=""
  105. 2730 p$(24)=""
  106. 2740 return
  107. 3000 forcl=8to19:printleft$(l$,cl)tab(14)"[154]                ":next
  108. 3010 printleft$(l$,p)tab(10)"[154]  ":return
  109. 4000 poke657,128:rem disable shift/com key
  110. 4010 rem poke775,200:rem disable listing
  111. 4020 rem poke808,234:rem disable stop/restore
  112. 4030 l$="":pt$="[154]=>":return
  113. 4100 sys828
  114. 4110 printleft$(l$,8)tab(1)"[159][176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  115. 4120 fori=9to14:printleft$(l$,i)tab(1)"[221]                                    [221]"
  116. 4125 next
  117. 4130 printleft$(l$,15)tab(1)"[221]   [158][[195]/[210]=[195]ancel * [211]pc=[210]un [208]rogram][159]   [221]"
  118. 4140 printleft$(l$,16)tab(1)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  119. 4145 printleft$(l$,23)tab(3)"[155]                                  ":gosub1000
  120. 4150 fori=1to5:printleft$(l$,8+i)tab(3)"[159]"in$(h,i):next
  121. 4160 getan$:ifan$=""then4160
  122. 4170 ifan$=chr$(13)thensys882:goto204
  123. 4180 ifh=3orh=5orh=8orh=14orh=21orh=22thensys882:goto1550
  124. 4190 ifan$=chr$(32)thensys882:goto230
  125. 4200 goto4160
  126. 5000 fori=828to935:reada:pokei,a:next:return
  127. 5010 data 160,0,185,0,4,153,0,192
  128. 5020 data 185,0,216,153,240,195,185,250
  129. 5030 data 4,153,250,192,185,250,216,153
  130. 5040 data 234,196,185,244,5,153,244,193
  131. 5050 data 185,244,217,153,228,197,185,238
  132. 5060 data 6,153,238,194,185,238,218,153
  133. 5070 data 222,198,200,208,205,96,160,0
  134. 5080 data 185,0,192,153,0,4,185,240
  135. 5090 data 195,153,0,216,185,250,192,153
  136. 5100 data 250,4,185,234,196,153,250,216
  137. 5110 data 185,244,193,153,244,5,185,228
  138. 5120 data 197,153,244,217,185,238,194,153
  139. 5130 data 238,6,185,222,198,153,238,218
  140. 5140 data 200,208,205,96
  141. 5799 rem ---------------------------
  142. 5800 rem ** max of 33 chrs in length **
  143. 5801 rem ---------------------------
  144. 5900 fori=1to24:forx=1to5:readin$(i,x):next:next:return
  145. 5999 rem program #1
  146. 6000 data "[212]his is [193]hoy!'s [205]achine [204]anguage "
  147. 6001 data "entry program for our adventurous"
  148. 6002 data "readers who like to type in the"
  149. 6003 data "programs from our magazine."
  150. 6004 data " "
  151. 6009 rem program #2
  152. 6010 data "[193]hoy!'s checksum program, for mis-"
  153. 6011 data "takeproof typing of [195]-64 [194][193][211][201][195] "
  154. 6012 data "programs printed in [193]hoy! ([198]or  "
  155. 6013 data "programs published before [205]ay 1987"
  156. 6014 data "only! [207]therwise use 64 [194]ug [210]ep. [201][201])"
  157. 6019 rem program #3
  158. 6020 data "[193]hoy!'s checksum program, for mis-"
  159. 6021 data "takeproof typing of [195]-128 [194][193][211][201][195]"
  160. 6022 data "programs printed in [193]hoy! ([198]or  "
  161. 6023 data "programs published before [205]ay 1987"
  162. 6024 data "only! [207]therwise use 128 [194]ug [210]ep [201][201])"
  163. 6029 rem program #4
  164. 6030 data "[193]hoy!'s checksum program, for mis-"
  165. 6031 data "takeproof typing of [195]-64 [194][193][211][201][195]    "
  166. 6032 data "programs printed in [193]hoy!. ([198]or    "
  167. 6033 data "programs published from [205]ay 1987 "
  168. 6034 data "only! [207]therwise use 64 [194]ug [210]ep.)
  169. 6039 [143] program #5
  170. 6040 [131] "atnhoy!'s checksum program, for mis- "
  171. 6041 [131] "takeproof typing of len-128closepeekatn(NULL)right$len "
  172. 6042 [131] "programs printed in atnhoy! (ascor pro-"
  173. 6043 [131] "grams published from (NULL)ay 1987 only!"
  174. 6044 [131] "(NULL)therwise use 128 peekug (NULL)epellent.)"
  175. 6049 [143] program #6
  176. 6050 [131] "(NULL)oondog places you in a spacecraft"
  177. 6051 [131] "with unlimited energy, all of which"
  178. 6052 [131] "you'll need to defend the planet "
  179. 6053 [131] "(NULL)oma against the alien fleet     "
  180. 6054 [131] "attacking it. mid$oystick in (NULL)ort 2."
  181. 6059 [143] program #7
  182. 6060 [131] "lenlimbing the side of a building   "
  183. 6061 [131] "might be easy for superheroes and"
  184. 6062 [131] "giant apes, but (NULL)all lenrawler will"
  185. 6063 [131] "challenge even the most experienced"
  186. 6064 [131] "gamers. mid$oystick in (NULL)ort 2."
  187. 6069 [143] program #8
  188. 6070 [131] "(NULL)tartup is a multipurpose str$(NULL)(NULL) util-"
  189. 6071 [131] "ity designed specifically for the"
  190. 6072 [131] "128. right$t contains all the popular   "
  191. 6073 [131] "str$(NULL)(NULL) functions, plus a routine for"
  192. 6074 [131] "creating autobootabale programs."
  193. 6079 [143] program #9
  194. 6080 [131] "(NULL)cavenger left$unt is a full-blown   "
  195. 6081 [131] "two-player arcade game featuring "
  196. 6082 [131] "two multicolor scrolling game   "
  197. 6083 [131] "windows. (NULL)he object is to find all"
  198. 6084 [131] "the items on your list and go home."
  199. 6089 [143] program #10
  200. 6090 [131] "chr$raphic (NULL)edge is a machine language"
  201. 6091 [131] "routine which adds 11 graphics- "
  202. 6092 [131]"enhancing commands to peekatn(NULL)right$len 2.0. "
  203. 6093 [131]"                                 "
  204. 6094 [131]"                               "
  205. 6099 [143] program #11
  206. 6100 [131]"right$llusion (NULL)aster allows you to make "
  207. 6101 [131]"any file name vanish from your disk"
  208. 6102 [131]"directory, or make the entire    "
  209. 6103 [131]"directory vanish if so desired.   "
  210. 6104 [131]"                                   "
  211. 6109 [143] program #12
  212. 6110 [131]"(NULL)olution to a lenommodare in the mid$an-"
  213. 6111 [131]"uary 1987 issue, requiring the    "
  214. 6112 [131]"reader to fill in the blanks in a  "
  215. 6113 [131]"matrix to create a 'magic square'."
  216. 6114 [131]"                                  "
  217. 6119 [143] program #13
  218. 6120 [131]"(NULL)ee (NULL)agic (NULL)quare. atnnother solution."
  219. 6121 [131]"                                  "
  220. 6122 [131]"                                  "
  221. 6123 [131]"                                  "
  222. 6124 [131]"                            "
  223. 6129 [143] program #14
  224. 6130 [131]"(NULL)ee (NULL)agic (NULL)quare. atn len-128 solution."
  225. 6131 [131]"                                 "
  226. 6132 [131]"                                 "
  227. 6133 [131]"                                  "
  228. 6134 [131]"                        "
  229. 6139 [143] program #15
  230. 6140 [131]"(NULL)olution to the mid$anuary 1987     "
  231. 6141 [131]"lenommodare, requiring the user to  "
  232. 6142 [131]"simulate a game of musical chairs  "
  233. 6143 [131]"on the 64.                        "
  234. 6144 [131]"                                 "
  235. 6149 [143] program #16
  236. 6150 [131]"(NULL)ee (NULL)utcast (NULL)rder. atnnother sol-"
  237. 6151 [131]"ution.                             "
  238. 6152 [131]"                                   "
  239. 6153 [131]"                                   "
  240. 6154 [131]"                                 "
  241. 6159 [143] program #17
  242. 6160 [131]"(NULL)ee (NULL)utcast (NULL)rder. atnnother sol-"
  243. 6161 [131]"ution.                             "
  244. 6162 [131]"                                   "
  245. 6163 [131]"                                   "
  246. 6164 [131]"                                  "
  247. 6169 [143] program #18
  248. 6170 [131]"(NULL)olution to the mid$anuary '87 lenomm-"
  249. 6171 [131]"odare, asking the user to find "
  250. 6172 [131]"digits atn,peek,len, and str$, if any, for"
  251. 6173 [131]"which the four-digit number atnpeeklenstr$  "
  252. 6174 [131]"equals the expression (atn^peek)*(len^str$)."
  253. 6179 [143] program #19
  254. 6180 [131]"(NULL)ee (NULL)ower (NULL)roduct. atnnother sol-    "
  255. 6181 [131]"ution.                            "
  256. 6182 [131]"                                  "
  257. 6183 [131]"                                  "
  258. 6184 [131]"                                  "
  259. 6189 [143] program #20
  260. 6190 [131]"(NULL)olution to the mid$anuary 1987      "
  261. 6191 [131]"lenommodare, requiring the reader  "
  262. 6192 [131]"to reverse an entire phrase.      "
  263. 6193 [131]"                                "
  264. 6194 [131]"                                "
  265. 6199 [143] program #21
  266. 6200 [131]"(NULL)ee (NULL)hrase (NULL)everser. atn len-128     "
  267. 6201 [131]"solution.                          "
  268. 6202 [131]"                                  "
  269. 6203 [131]"                                  "
  270. 6204 [131]"                            "
  271. 6209 [143] program #22
  272. 6210 [131]"atn handy function key utility for "
  273. 6211 [131]"the len-128, presented as part of  "
  274. 6212 [131]"this month's (NULL)upert (NULL)eport on    "
  275. 6213 [131]"(NULL)ernal (NULL)ower.                   "
  276. 6214 [131]"                            "
  277. 6219 [143] program #23
  278. 6220 [131]"(NULL)ot (NULL)sed.....                      "
  279. 6221 [131]"                                  "
  280. 6222 [131]"                                   "
  281. 6223 [131]"                                  "
  282. 6224 [131]"                               "
  283. 6229 [143] program #24
  284. 6230 [131]"(NULL)ot (NULL)sed.....                   "
  285. 6231 [131]"                                 "
  286. 6232 [131]"                                 "
  287. 6233 [131]"                                   "
  288. 6234 [131]"                             "
  289.